package com.ylr.jwt.framework.properties;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * Created by IntelliJ IDEA.
 *
 * @author wyw
 * date: 2023-04-26 14:08:22
 * className: JwtProperties
 * version: 1.0
 * description:
 */
@Getter
@Setter
@ToString
@Component
@ConfigurationProperties(prefix = "jwt")
public class JwtProperties {

    /**
     * web端jwt配置
     */
    private Config web;


    @Getter
    @Setter
    @ToString
    public static class Config {

        /**
         * 密钥
         */
        private String secret;
        /**
         * 短令牌过期时长，单位毫秒
         */
        private Long expire;
        /**
         * 长短令牌过期时长，单位毫秒
         */
        private Long refreshExpire;

    }
}
